﻿<!DOCTYPE HTML>
<html>
<head>
<meta charset="utf-8">
<meta name="renderer" content="webkit|ie-comp|ie-stand">
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
<meta name="viewport" content="width=device-width,initial-scale=1,minimum-scale=1.0,maximum-scale=1.0,user-scalable=no" />
<meta http-equiv="Cache-Control" content="no-siteapp" />
<link rel="stylesheet" type="text/css" href="../static/h-ui/css/H-ui.min.css" />
<link rel="stylesheet" type="text/css" href="../static/h-ui.admin/css/H-ui.admin.css" />
<link rel="stylesheet" type="text/css" href="../lib/Hui-iconfont/1.0.7/iconfont.css" />
<link rel="stylesheet" type="text/css" href="../lib/icheck/icheck.css" />
<link rel="stylesheet" type="text/css" href="../static/h-ui.admin/skin/default/skin.css" id="skin" />
<link rel="stylesheet" type="text/css" href="../static/h-ui.admin/css/style.css" />
<link rel="stylesheet" type="text/css" href="../static/eth/css/airline.css" />
<link rel="stylesheet" type="text/css" href="../lib/jquery.pagination/css/pagination.css" />
<script type="text/javascript" src="../lib/jquery/1.9.1/jquery.min.js"></script> 
<script type="text/javascript" src="../lib/layer/2.1/layer.js"></script> 
<script type="text/javascript" src="../lib/icheck/jquery.icheck.min.js"></script> 
<script type="text/javascript" src="../lib/My97DatePicker/WdatePicker.js"></script> 
<script type="text/javascript" src="../lib/datatables/1.10.0/jquery.dataTables.min.js"></script> 
<script type="text/javascript" src="../static/h-ui/js/H-ui.js"></script> 
<script type="text/javascript" src="../static/h-ui.admin/js/H-ui.admin.js"></script> 
<script type="text/javascript" src="../lib/jquery.pagination/jquery.pagination.js"></script> 
<script type="text/javascript" src="../static/eth/js/pagination.js"></script>
<title>航司列表</title>
</head>
<body>
	<nav class="breadcrumb">
		<i class="Hui-iconfont">&#xe67f;</i> 首页 <span class="c-gray en">&gt;</span>
		基础信息 <span class="c-gray en">&gt;</span> 航司列表<a
			class="btn btn-success radius r"
			style="line-height: 1.6em; margin-top: 3px"
			href="javascript:location.replace(location.href);" title="刷新"><i
			class="Hui-iconfont">&#xe68f;</i></a>
	</nav>
	<div class="page-container">
	<div class="text-c">
	    <form id="form" action="list" method="get">
		<input type="text" name="airlineCode" value="${cond.airlineCode!''}" placeholder=" 二字码或名字" style="width:120px" class="input-text">
		<input type="text" style="display:none" name="pageIndex" id="pageIndex" value="${page.curIndex!''}"/>
		<input type="text" style="display:none" name="pageSize" id="pageSize" value="${page.pageSize!''}" />
		<input type="text" style="display:none" name="rowsCount" id="rowsCount" value="${page.rowsCount!''}" />
		<button name="" id="" class="btn btn-success" type="submit" onclick="$('#pageIndex').val(1);"><i class="Hui-iconfont">&#xe665;</i> 搜索</button>
	    </form>
	</div>
		<div class="cl pd-5 bg-1 bk-gray mt-20">
			<span class="l">
			    <a class="btn btn-primary radius" onclick="airline_add('添加航司','editPage')" href="javascript:;"><i class="Hui-iconfont">&#xe600;</i> 添加航司</a>
			    <a href="javascript:;" onclick="updatefromfile()" class="btn btn-danger radius"><i class="Hui-iconfont">&#xe6e2;</i>从文件同步</a>
			</span>
		</div>
		<div class="mt-20">
		<table class="table table-border table-bordered table-bg table-hover table-sort">
			<thead>
				<tr class="text-c">
					<th width="40">ID</th>
					<th width="20">二字码</th>
					<th width="20">图标</th>
					<th width="80">名称</th>
					<th width="80">英文名</th>
					<th width="80">操作</th>
				</tr>
			</thead>
			<tbody class="text-c">
			    <#list page.items! as airline>
				<tr class="text-c">
				    <td class="td-id">${airline.airlineId!}</td>
					<td class="text-c">${airline.airlineCode!}</td>
					<td class="text-c"><div class="airwayslogo-${airline.airlineCode}"></div></td>
					<td class="text-c">${airline.airlineName!}</td>
					<td class="text-c">${airline.airlineNameEn!}</td>
					<td class="td-manage">
					    <a style="text-decoration:none" class="ml-5" onClick="airline_edit('航司编辑','editPage?airlineId=${airline.airlineId}','10001')" href="javascript:;" title="编辑"><i class="Hui-iconfont">&#xe6df;</i></a> 
					    <a style="text-decoration:none" class="ml-5" onClick="airline_del(this,'10001')" href="javascript:;" title="删除"><i class="Hui-iconfont">&#xe6e2;</i></a>
					</td>
				</tr>
				</#list>
			</tbody>
		</table>
	</div>
	<div id="Pagination" class="pagination mt-20"></div>
</div>
<script type="text/javascript">
/*政策-添加*/
function airline_add(title,url){
	var index = layer.open({
		type: 2,
		title: title,
		content: url
	});
	layer.full(index);
}
/*政策-查看*/
function airline_show(title,url,id){
	var index = layer.open({
		type: 2,
		title: title,
		content: url
	});
	layer.full(index);
}
/*政策-编辑*/
function airline_edit(title,url,id){
	layer.close();
	var index = layer.open({
		type: 2,
		title: title,
		content: url
	});
	layer.full(index);
}
/*政策-删除*/
function airline_del(obj,id){
	layer.confirm('确认要删除吗？',function(index){
		ajaxSubmit('POST', 'delete', 'airlineId=' + $(obj).parents("tr").find(".td-id").html());
	});
}
function updatefromfile(){
	ajaxSubmit('POST', 'updatefromfile');
}
</script>
</body>
</html>